<link type="text/css" href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/4.3.1/css/bootstrap.min.css" rel="stylesheet">
<script type="text/javascript" src="https://cdn.bootcdn.net/ajax/libs/popper.js/1.14.7/umd/popper.min.js"></script>
<script type="text/javascript" src="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/4.3.1/js/bootstrap.min.js"></script>



<!-- 文档地址 https://getbootstrap.net/docs/components/buttons/ -->
<button type="button" class="btn btn-outline-primary">Primary</button>

<script type="text/javascript">
	//按钮的点击事件
	$('button[type=button].btn').click(function(){
		console.log($(this).index());
	});
</script>
